

**analysis with ANES 2016 data
**The file MainAnalysis_S1.do must be run first (and figures saved) for this file to run (or skip combining the figures).  

*Change the directory to the location of the replication files on your computer
cd "C:\PCult_Replication"

*do "anes_clean.do"

use "anes_vars_2016.dta"



*svyset [pweight=V160102], strata(V160201) psu(V160202)

*Missing standard errors because of stratum with single sampling unit.

hist TrumpIndex_S2

svyset [pweight=V160102]

svy: mean TrumpIndex_S2 if ConservativePRE1~=. & Openness1~=. & Extraversion1~=. & Agreeableness1 ~=. & Conscientiousness1 ~=. & Stability1~=.
estat sd
*mean = .3226153 
**This is the mean value used in the main analysis

   set scheme stcolor

*get the centiles for each
 
 centile ConservativePRE1 Republican  Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1, centile(5 95)
 
 /*
                                                           Binom. interp.   
    Variable |       Obs  Percentile    Centile        [95% conf. interval]
-------------+-------------------------------------------------------------
Conservat~E1 |     3,303          5    .1666667               0    .1666667
             |                   95           1        .8333333           1
  Republican |     4,245          5           0               0           0
             |                   95           1               1           1
   Openness1 |     3,588          5    .3333333        .3333333    .4166667
             |                   95           1               1           1
  Stability1 |     3,596          5    .3333333             .25    .3333333
             |                   95           1               1           1
Agreeablen~1 |     3,588          5    .4166667        .4166667    .4166667
             |                   95           1               1           1
Extraversi~1 |     3,589          5    .1666667        .1666667    .1666667
             |                   95    .9166667        .9166667    .9166667
Conscienti~1 |     3,594          5          .5        .4166667          .5
             |                   95           1               1           1

*/

centile ConservativePRE1 Republican  Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1 if TrumpIndex_S2> .3226153 & TrumpIndex_S2~=., centile(5 95)

/*
                                                         Binom. interp.   
    Variable |       Obs  Percentile    Centile        [95% conf. interval]
-------------+-------------------------------------------------------------
Conservat~E1 |     1,340          5          .5        .3333333          .5
             |                   95           1               1           1
  Republican |     1,661          5           0               0           0
             |                   95           1               1           1
   Openness1 |     1,403          5    .3333333        .3333333    .4166667
             |                   95    .9166667        .9166667           1
  Stability1 |     1,408          5    .3333333             .25    .3333333
             |                   95           1               1           1
Agreeablen~1 |     1,405          5    .4166667        .3333333    .4166667
             |                   95           1               1           1
Extraversi~1 |     1,406          5    .1666667        .1666667    .1666667
             |                   95    .9166667        .9166667    .9166667
Conscienti~1 |     1,407          5          .5              .5          .5
             |                   95           1               1           1


*/

****Figure 2

*Personality only
 
svy: logit TrumpCult90 Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1 if TrumpIndex_S2> .3226153 & TrumpIndex_S2~=.
 

margins if Openness1>.333 & Stability1>.333 & Agreeableness1 > .416 & Extraversion1 > .166 &  Extraversion1 < .917 & Conscientiousness1 > .5, dydx( *) 
 
marginsplot,  title("Study 2 (TIPI)") subtitle("") ytitle("") derivlabels  xtitle("") horizontal plotopts(connect(none))  xline(0) xscale(r(-.6 .8)) xlabel(-.6(.4).8) xtick(-.6(.4).8)
 
 graph save "Graph" "meanS201.gph", replace 
 
*Personality w controls

svy: logit TrumpCult90 ConservativePRE1 Republican  Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1 if TrumpIndex_S2> .3226153 & TrumpIndex_S2~=.
 
margins if ConservativePRE1>.5 & Openness1>.333 & Stability1>.333 & Agreeableness1 > .416 & Extraversion1 > .166 &  Extraversion1 < .917 & Conscientiousness1 > .5, dydx( *) 
 

marginsplot,  title("Study 2 (TIPI and Controls)") subtitle("") ytitle("") derivlabels  xtitle("") horizontal plotopts(connect(none))  xline(0) xscale(r(-.6 .8)) xlabel(-.6(.4).8) xtick(-.6(.4).8)

graph save "Graph" "meanS202.gph", replace 
 
graph combine meanS101.gph meanS102.gph meanS201.gph meanS202.gph , rows(2) cols(2)  title(Trump Followers) name(means, replace) saving(means, asis replace)
  
  
*Figure 3
******Trump Index Dep Var >0.9
  
set scheme stcolor
 
gen TrumpIndex09_S2 = 0 if TrumpIndex_S2~=.
replace TrumpIndex09_S2 = 1 if TrumpIndex_S2>0.9 & TrumpIndex_S2~=.
  
svy: logit TrumpIndex09_S2 ConservativePRE1 Republican  Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1 if TrumpIndex_S2> .3226153  & TrumpIndex_S2~=.
 
margins if ConservativePRE1>.5 & Openness1>.333 & Stability1>.333 & Agreeableness1 > .416 & Extraversion1 > .166 &  Extraversion1 < .917 & Conscientiousness1 > .5, dydx( *) 
 
marginsplot,  title("Study 2 (TIPI and Controls)") subtitle("") ytitle("") derivlabels  xtitle("") subtitle("Trump Index > 0.9") horizontal plotopts(connect(none))  xline(0) xscale(r(-.6 .8)) xlabel(-.6(.4).8) xtick(-.6(.4).8)

graph save "Graph" "mean09_S2.gph", replace 
 
****Republican Primary Voters


**Identify primary voters

tab V161021
tab V161021a
tab V161021 V161021a

gen PrimaryVoter = 0
replace PrimaryVoter = 1 if V161021==1

gen RPrimaryVoter = 0 if PrimaryVoter==1
replace RPrimaryVoter = 1 if V161021a>=4 & V161021a<=8

gen DPrimaryVoter = 0 if PrimaryVoter==1
replace DPrimaryVoter = 1 if V161021a>=1 & V161021a<=3

gen TPrimaryVoter = 0 if PrimaryVoter==1
replace TPrimaryVoter = 1 if V161021a==4

tab PrimaryVoter DPrimaryVoter
tab RPrimaryVoter TPrimaryVoter

tab TrumpCult90 TPrimaryVoter

**** 
svy: logit TrumpCult90 ConservativePRE1  Openness1 Stability1 Agreeableness1 Extraversion1 Conscientiousness1 if RPrimaryVoter==1 
 
margins if ConservativePRE1 > .5 & Openness1>.3333333 & Stability1 > .3333333 &  Agreeableness1 >  .4166667 & Extraversion1 > .1666667  & Extraversion1< .9166667 & Conscientiousness1 > .5, dydx( *)
 
marginsplot,  title("Study 2 (TIPI & Conservative)") subtitle("Republican Primary Voters") ytitle("") derivlabels  xtitle("") horizontal plotopts(connect(none)) xline(0) xscale(r(-.6 1.0)) xlabel(-.6(.2)1.0) xtick(-.6(.2)1.0)

graph save "Graph" "PrimS202.gph", replace 

***Make Figure
 
graph combine mean09_S1.gph GOPS102.gph mean09_S2.gph PrimS202.gph, rows(2) cols(2)  title("") name(means, replace) saving(means, asis replace)
  
 
 
 
 
 
 